<template>
  <div class="data1">
    <div class="data_1">
      <div class="ser">
        <p class="ser_title">
          <span>服务编号</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.id }} </span>
        </p>
      </div>
      <div class="ser">
        <p class="ser_title">
          <span>服务状态</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.state==1?  "待审核" : serviceInfo.state==2?  "待服务":"以驳回"}} </span>
        </p>
      </div>

      <div class="ser">
        <p class="ser_title">
          <span>服务机构</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.mechanism==1?  "罗西社区服务中心" : serviceInfo.mechanism==2?  "天明社区服务中心":"民进社区服务中心" }} </span>
          
        </p>
      </div>
    </div>
    <!-- 第二行数据 -->
    <div class="data_1">
      <div class="ser">
        <p class="ser_title">
          <span>服务团队</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.doctor_team==1?  "李维团队" : serviceInfo.doctor_team==2?  "胡曼团队":"王皓团队" }} </span>
           
        </p>
      </div>
      <div class="ser">
        <p class="ser_title">
          <span>服务医生</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.doctor }} </span>
        </p>
      </div>

      <div class="ser">
        <p class="ser_title">
          <span>服务包</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.service==1?  "0-6岁儿童服务包" : serviceInfo.service==2?  "老年人服务包":"慢性病护理包" }} </span>
          
        </p>
      </div>
    </div>

    <!-- 第三行数据 -->
    <div class="data_1">
      <div class="ser">
        <p class="ser_title">
          <span>服务项目</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.sex }} </span>
        </p>
      </div>
      <div class="ser">
        <p class="ser_title">
          <span>服务地点</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.current_residence }} </span>
        </p>
      </div>

      <div class="ser">
        <p class="ser_title">
          <span>服务来源</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.administrative_division }} </span>
        </p>
      </div>
    </div>

    <!-- 第五行数据 -->
    <div class="data_1">
      <div class="ser">
        <p class="ser_title">
          <span>提交时间</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.application_time }} </span>
        </p>
      </div>
      <div class="ser">
        <p class="ser_title">
          <span>审核时间</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.application_time }} </span>
        </p>
      </div>

      <div class="ser">
        <p class="ser_title">
          <span>审核人</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.emergency_contact }} </span>
        </p>
      </div>
    </div>
    <div class="data_1">
      <div class="ser">
        <p class="ser_title">
          <span>服务时间</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.application_time }} </span>
        </p>
      </div>
      <div class="ser">
        <p class="ser_title">
          <span>服务备注</span>
        </p>
        <p class="ser_data_3">
          <span> {{ serviceInfo.emergency_contact }} </span>
        </p>
      </div>
    </div>
  </div>
</template>

<script>
import axios from "axios";
export default {
  props: ["signRecordId"],
  data() {
    return {
      serviceInfo: {},
    };
  },
  methods: {
    
    getServiceInfo() {
      axios({
        url: "api/inhabitant/findInhabitantById",
        method: "get",
        params:{
          id:this.signRecordId
        }
      }).then((res) => {
         this.serviceInfo = res.data;
        //  alert(this.signRecordId+"asdsadas")
      });
     
    },
    
  },
  created () {
    this.getServiceInfo();
  }
  
};
</script>

<style>
.data1 {
  width: 890px;
  height: 290px;
  margin-bottom: 10px;
  background-color: #f2f7fb;
}
.data_1 {
  width: 890px;
  height: 60px;
  line-height: 60px;
}
.ser_title {
  font-size: 16px;
  float: left;
  color: gray;
  width: 70px;
}
.ser_data {
  width: 150px;
  font-size: 16px;
  float: left;
  margin-left: 10px;
  margin-right: 10px;
}
.ser_data_1 {
  width: 250px;
  font-size: 16px;
  float: left;
  margin-left: 10px;
}
.ser {
  float: left;
}
.ser_data_3 {
  width: 200px;
  font-size: 16px;
  float: left;
  margin-left: 10px;
  margin-right: 10px;
}

span {
  font-size: 14px;
}
</style>